package com.myapp.ruyixing.http;

import org.json.JSONObject;

import com.myapp.ruyixing.model.DirectMessageDetail;
import com.myapp.ruyixing.model.ReplyList;

public class DMDetailParser extends RYJSONParser {

	@Override
	public Object parse(JSONObject jsonObject) {
		if (getErrno(jsonObject) != NO_ERROR) {
			return null;
		}

		JSONObject data = jsonObject.optJSONObject("data");
		
		DirectMessageDetail o = new DirectMessageDetail();

		if (jsonObject != null) {
			o = loadByGson(data, DirectMessageDetail.class);
		}

		return o;
	}
}
